<template>
	<view class="home">
		<view class="nav">
			<view class="text-right">
				<image src="../../static/icon/text-left.svg" mode=""></image>
			</view>
			<view class="person-circle">
				<image src="../../static/icon/person-fill.svg" mode=""></image>
			</view>
		</view>
		<view class="search">
			<input type="text" value="搜索" class="searchText" />
			<image src="../../static/icon/search.svg" mode=""></image>
		</view>
		<view class="chatPanel">
			<view class="contain">
				<view class="chatItem">
					<view class="classImage">
						<text class="imageName">面</text>
					</view>
					<text class="className">面向对象程序设计</text>
					<text class="message">程时：完成第一章课后作业。</text>
					<text class="time">03-08 11:10</text>
				</view>
				<view class="chatItem">
					<view class="classImage">
						<text class="imageName">面</text>
					</view>
					<text class="className">面向对象程序设计</text>
					<text class="message">程时：完成第一章课后作业。</text>
					<text class="time">03-08 11:10</text>
				</view>
				<view class="chatItem">
					<view class="classImage">
						<text class="imageName">面</text>
					</view>
					<text class="className">面向对象程序设计</text>
					<text class="message">程时：完成第一章课后作业。</text>
					<text class="time">03-08 11:10</text>
				</view>
				<view class="chatItem">
					<view class="classImage">
						<text class="imageName">面</text>
					</view>
					<text class="className">面向对象程序设计</text>
					<text class="message">程时：完成第一章课后作业。</text>
					<text class="time">03-08 11:10</text>
				</view>
				<view class="chatItem">
					<view class="classImage">
						<text class="imageName">面</text>
					</view>
					<text class="className">面向对象程序设计</text>
					<text class="message">程时：完成第一章课后作业。</text>
					<text class="time">03-08 11:10</text>
				</view>
				<view class="chatItem">
					<view class="classImage">
						<text class="imageName">面</text>
					</view>
					<text class="className">面向对象程序设计</text>
					<text class="message">程时：完成第一章课后作业。</text>
					<text class="time">03-08 11:10</text>
				</view>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {

			}
		},
		methods: {

		}
	}
</script>

<style lang="scss">
	.home {
		margin: 0 auto;
		padding: 0;

		// position: relative;
		.nav {
			width: 340px;
			height: 44px;
			margin: 0 auto;

			// background-color: blue;
			.text-right {
				float: left;
				margin-top: 6px;

				// margin-left: 20px;
				image {
					width: 32px;
					height: 32px;
				}
			}

			.person-circle {
				position: relative;
				float: right;
				margin-top: 6px;
				// margin-right: 20px;
				width: 32px;
				height: 32px;
				background-color: #d9d9d9;
				border-radius: 16px;

				image {
					position: absolute;
					width: 18px;
					height: 18px;
					top: 50%;
					left: 50%;
					transform: translate(-50%, -50%);
				}
			}
		}

		.search {
			display: flex;
			align-items: center;
			margin: 16px auto 20px;
			padding: 0 16px;
			width: 340px;
			height: 52px;
			// background-color: blue;
			box-sizing: border-box;
			border-radius: 4px;
			box-shadow: 0 4px 20px rgba(0, 0, 0, 0.16);
			backdrop-filter: blur(20px);
			overflow: hidden;

			.searchText {
				flex: 1;
				// border: none;
				// outline: none;
				// padding: 0 16px;
				height: 100%;
				font-size: 16px;
				font-family: Arial, Helvetica, sans-serif;
				color: #999999;
			}

			image {
				// float: right;
				// margin: auto ;
				width: 20px;
				height: 20px;
			}

		}

		.chatPanel {
			margin: 0 auto;
			width: 340px;
			height: 514px;

			// background-color: skyblue;
			.contain {
				.chatItem {
					position: relative;
					height: 90px;
					margin-bottom: 16px;
					padding: 20px;
					box-sizing: border-box;
					border-radius: 4px;
					box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
					backdrop-filter: blur(20px);

					.classImage {
						// display: inline-block;
						width: 52px;
						height: 52px;
						background-color: #d9d9d9;
						border-radius: 4px;
						text-align: center;

						.imageName {
							display: flex;
							justify-content: center;
							align-items: center;
							text-align: center;
							height: 100%;
							font-size: 32px;
							font-family: Arial, Helvetica, sans-serif;
						}
					}

					.className {
						position: absolute;
						top: 20px;
						left: 82px;
						font-size: 15px;
						font-family: Arial, Helvetica, sans-serif;
					}

					.message {
						position: absolute;
						top: 54px;
						left: 82px;
						font-size: 13px;
						font-family: Arial, Helvetica, sans-serif;
						color: rgba(0, 0, 0, 0.71);
					}

					.time {
						position: absolute;
						top: 21px;
						right: 23px;
						font-size: 13px;
						font-family: Arial, Helvetica, sans-serif;
					}
				}
			}
		}
	}
</style>